/* =========================================================
   MERARY — компактный premium-блок "Дополните подарок"
   Цель: 560–620px общей высоты на desktop.
   Вставлять после "Хитов продаж".
   ========================================================= */

.merary-gift-upgrade {
  --merary-shell: #fffdfc;
  --merary-card: #fffdfc;
  --merary-border: rgba(226, 190, 196, 0.58);
  --merary-border-hover: rgba(237, 199, 207, 0.95);
  --merary-text: #2d2725;
  --merary-muted: #8f8583;
  --merary-accent: var(--pink-accent, #ff5d83);

  position: relative;
  /* Внешний воздух задаёт --home-block-gap на главной */
  padding: var(--home-block-gap, clamp(22px, 2.8vw, 36px)) 0;
  margin: 0;
  background: transparent;
  color: var(--merary-text);
  font-family: var(--font-sans, 'Montserrat', Arial, Helvetica, sans-serif);
}

.merary-gift-upgrade *,
.merary-gift-upgrade *::before,
.merary-gift-upgrade *::after {
  box-sizing: border-box;
}

.merary-gift-upgrade__shell {
  position: relative;
  /* Ровно по .container — как why-delivery__layout и #bestsellers */
  width: 100%;
  max-width: none;
  margin: 0;
  /* Без бокового padding: иначе карточки «уезжают» внутрь относительно хитов / why-us */
  padding: 28px 0 22px;
  overflow: hidden;
  box-sizing: border-box;

  background: rgba(255, 255, 255, 0.91);
  border: none;
  border-radius: 30px;
  /* border через box-shadow — иначе +1px съедает край и карточки смещаются относительно why-us */
  box-shadow:
    0 0 0 1px rgba(238, 212, 216, 0.82),
    0 18px 55px rgba(145, 89, 98, 0.05);
}

.merary-gift-upgrade__glow {
  position: absolute;
  width: 230px;
  height: 230px;
  pointer-events: none;
  opacity: 0.42;
  filter: blur(24px);
  background: radial-gradient(
    circle,
    rgba(255, 184, 194, 0.3) 0%,
    rgba(255, 215, 219, 0.13) 45%,
    transparent 74%
  );
}

.merary-gift-upgrade__glow--left {
  left: -80px;
  top: 8px;
}

.merary-gift-upgrade__glow--right {
  right: -70px;
  top: 5px;
}

.merary-gift-upgrade__header {
  position: relative;
  z-index: 2;
  text-align: center;
  margin-bottom: 22px;
  padding: 0 24px;
  box-sizing: border-box;
}

.merary-gift-upgrade__eyebrow {
  margin-bottom: 8px;
  color: #ef8aa2;
  font-size: 11px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.18em;
}

.merary-gift-upgrade__title {
  margin: 0 auto;
  max-width: 100%;
  padding: 0;
  font-family: var(--font-serif, 'Playfair Display', Georgia, 'Times New Roman', serif);
  font-size: clamp(30px, 2vw, 42px);
  line-height: 1.08;
  font-weight: 400;
  letter-spacing: -0.02em;
  color: #2f2927;
  box-sizing: border-box;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.merary-gift-upgrade__title span {
  color: var(--merary-accent);
  font-size: 0.82em;
}

.merary-gift-upgrade__subtitle {
  margin: 7px 0 0;
  color: #827a78;
  font-size: 14px;
  line-height: 1.4;
}

.merary-gift-upgrade__grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
  padding: 0;
  margin: 0;
}

.merary-gift-card {
  display: flex;
  min-width: 0;
  min-height: 365px;
  flex-direction: column;
  overflow: hidden;

  background: rgba(255, 253, 252, 0.96);
  border: 1px solid var(--merary-border);
  border-radius: 22px;
  box-shadow: 0 10px 28px rgba(121, 73, 84, 0.05);

  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    border-color 0.2s ease;
}

.merary-gift-card:hover {
  transform: translateY(-3px);
  border-color: var(--merary-border-hover);
  box-shadow: 0 15px 34px rgba(132, 75, 87, 0.085);
}

.merary-gift-card__image-link {
  display: block;
  height: 205px;
  overflow: hidden;
  background: #f9e7e5;
}

.merary-gift-card__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.35s ease;
}

.merary-gift-card__image.is-cms-layout {
  width: var(--cms-w, 100%);
  max-width: none;
  height: 100%;
  transform: translate(var(--cms-tx, 0%), var(--cms-ty, 0%)) scale(var(--cms-scale, 1));
  transform-origin: center center;
  transition: none;
}

.merary-gift-card:hover .merary-gift-card__image:not(.is-cms-layout) {
  transform: scale(1.018);
}

.merary-gift-card__content {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 15px 20px 16px;
}

.merary-gift-card__heading-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

.merary-gift-card__icon {
  display: grid;
  width: 22px;
  height: 22px;
  place-items: center;
  flex: 0 0 22px;
  color: var(--merary-accent);
  font-size: 16px;
  line-height: 1;
}

.merary-gift-card__title {
  margin: 0;
  font-family: var(--font-serif, 'Playfair Display', Georgia, 'Times New Roman', serif);
  font-size: 21px;
  line-height: 1.08;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.merary-gift-card__text {
  margin: 0 0 14px;
  color: var(--merary-muted);
  font-size: 13px;
  line-height: 1.4;
}

.merary-gift-card__cta {
  display: inline-flex;
  width: max-content;
  max-width: 100%;
  align-items: center;
  gap: 9px;
  margin-top: auto;
  padding: 8px 14px;

  color: var(--merary-accent);
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 93, 131, 0.5);
  border-radius: 999px;

  font-size: 11px;
  line-height: 1;
  font-weight: 700;
  text-decoration: none;

  transition: all 0.2s ease;
}

.merary-gift-card__cta span {
  transition: transform 0.2s ease;
}

.merary-gift-card__cta:hover {
  color: #fff;
  background: var(--merary-accent);
  border-color: var(--merary-accent);
}

.merary-gift-card__cta:hover span {
  transform: translateX(3px);
}

.merary-gift-upgrade__footer-note {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr auto auto 1fr;
  align-items: center;
  gap: 14px;
  margin-top: 20px;
  padding: 0 18px;
}

.merary-gift-upgrade__footer-note p {
  margin: 0;
  color: #817876;
  font-size: 12px;
  line-height: 1.3;
  white-space: nowrap;
}

.merary-gift-upgrade__footer-note p span {
  color: var(--merary-accent);
}

.merary-gift-upgrade__footer-line {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(224, 188, 194, 0.65));
}

.merary-gift-upgrade__footer-line:last-child {
  background: linear-gradient(90deg, rgba(224, 188, 194, 0.65), transparent);
}

.merary-gift-upgrade__footer-flower {
  color: var(--merary-accent);
  font-size: 17px;
}

@media (max-width: 1440px) {
  .merary-gift-upgrade__shell {
    padding: 24px 0 20px;
  }

  .merary-gift-upgrade__header {
    padding: 0 20px;
  }

  .merary-gift-upgrade__grid {
    gap: 16px;
  }

  .merary-gift-card {
    min-height: 345px;
  }

  .merary-gift-card__image-link {
    height: 190px;
  }

  .merary-gift-card__title {
    font-size: 20px;
  }
}

@media (max-width: 1100px) {
  .merary-gift-upgrade__shell {
    padding: 22px 0 18px;
  }

  .merary-gift-upgrade__header {
    padding: 0 16px;
  }

  .merary-gift-upgrade__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .merary-gift-card__image-link {
    height: 230px;
  }

  .merary-gift-upgrade__footer-note {
    grid-template-columns: 1fr auto 1fr;
    padding: 0 16px;
  }

  .merary-gift-upgrade__footer-note p {
    grid-column: 1 / -1;
    grid-row: 2;
    text-align: center;
    white-space: normal;
  }

  .merary-gift-upgrade__footer-flower {
    grid-column: 2;
  }
}

@media (max-width: 680px) {
  .merary-gift-upgrade__shell {
    padding: 22px 0 18px;
    border-radius: 22px;
  }

  .merary-gift-upgrade__header {
    margin-bottom: 18px;
    padding: 0 14px;
  }

  .merary-gift-upgrade__eyebrow {
    font-size: 10px;
  }

  .merary-gift-upgrade__title {
    font-size: 30px;
  }

  .merary-gift-upgrade__subtitle {
    font-size: 13px;
  }

  .merary-gift-upgrade__grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .merary-gift-card {
    min-height: 0;
    border-radius: 18px;
  }

  .merary-gift-card__image-link {
    height: 220px;
  }

  .merary-gift-card__content {
    padding: 15px 16px 16px;
  }

  .merary-gift-card__title {
    font-size: 20px;
  }

  .merary-gift-upgrade__footer-note {
    margin-top: 18px;
  }
}


@media (min-width: 53.1875rem) {
  .merary-gift-upgrade:not(.is-gift-ready) {
    display: none;
  }
}

.gift-hero {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 18px;
  max-width: 1240px;
  margin: 0 auto;
  padding: 22px 18px 20px;
  overflow: hidden;
  border-radius: 28px;
  background:
    radial-gradient(90% 80% at 92% 18%, rgba(255, 214, 210, 0.55), transparent 52%),
    radial-gradient(70% 80% at 8% 100%, rgba(255, 244, 236, 0.95), transparent 48%),
    linear-gradient(108deg, #fffaf8 0%, #fdf1ee 42%, #f7e4e1 100%);
}

.gift-hero__copy {
  display: contents;
}

.gift-hero__eyebrow {
  order: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin: 0;
  color: #D94E7B;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.22em;
  line-height: 1;
  text-transform: uppercase;
}

.gift-hero__eyebrow::after {
  content: "";
  width: 42px;
  height: 1px;
  background: rgba(217, 78, 123, 0.72);
}

/* Experiment: one sheen across the eyebrow and its line. Delete this block and js/gift-eyebrow.js to roll back. */
@media (prefers-reduced-motion: no-preference) {
  .gift-hero.is-eyebrow-arm .gift-hero__eyebrow-label {
    background-color: #D94E7B;
    background-image: linear-gradient(90deg, rgba(255, 226, 234, 0) 0%, rgba(255, 206, 220, 0.55) 32%, rgba(255, 244, 247, 0.98) 50%, rgba(255, 206, 220, 0.55) 68%, rgba(255, 226, 234, 0) 100%);
    background-repeat: no-repeat;
    background-size: 36px 100%;
    background-position: -40px 0;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gift-sheen-text 4.5s linear infinite;
    animation-play-state: paused;
  }

  .gift-hero.is-eyebrow-arm .gift-hero__eyebrow::after {
    background-color: rgba(217, 78, 123, 0.72);
    background-image: linear-gradient(90deg, rgba(255, 226, 234, 0) 0%, rgba(255, 244, 247, 0.98) 50%, rgba(255, 226, 234, 0) 100%);
    background-repeat: no-repeat;
    background-size: 16px 100%;
    background-position: -20px 0;
    animation: gift-sheen-line 4.5s linear infinite;
    animation-play-state: paused;
  }

  .gift-hero.is-eyebrow-arm.is-eyebrow-on .gift-hero__eyebrow-label,
  .gift-hero.is-eyebrow-arm.is-eyebrow-on .gift-hero__eyebrow::after {
    animation-play-state: running;
  }
}

@keyframes gift-sheen-text {
  0% { background-position: -40px 0; }
  18% { background-position: calc(100% + 44px) 0; }
  100% { background-position: calc(100% + 44px) 0; }
}

@keyframes gift-sheen-line {
  0%, 14% { background-position: -20px 0; }
  22.22% { background-position: 58px 0; }
  100% { background-position: 58px 0; }
}

.gift-hero__title {
  order: 2;
  margin: 0;
  color: #241f1e;
  font-family: var(--font-serif, 'Playfair Display', Georgia, 'Times New Roman', serif);
  font-size: clamp(32px, 8.4vw, 40px);
  font-weight: 500;
  line-height: 1.02;
  letter-spacing: -0.03em;
  text-align: center;
}

.gift-hero__title em {
  color: #e58aa3;
  font-style: italic;
  font-weight: 400;
}

.gift-hero__visual {
  order: 3;
  width: min(100%, 420px);
  margin: 0 auto;
  overflow: hidden;
  aspect-ratio: 5 / 4;
}

.gift-hero .gift-hero__photo {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 76% 40%;
}

.gift-hero__lead {
  order: 4;
  margin: 0 auto;
  max-width: 34ch;
  color: #6d6663;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.45;
  text-align: center;
}

.gift-hero__btn {
  order: 5;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  align-self: center;
  min-height: 46px;
  margin: 0 auto;
  padding: 0 22px;
  border: 0;
  border-radius: 999px;
  background: #e57d98;
  color: #fff;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.gift-hero__btn:hover {
  background: #d96b88;
}

.gift-hero__btn:focus-visible,
.gift-chip:focus-visible {
  outline: 2px solid #e57d98;
  outline-offset: 3px;
}

.gift-hero__chips {
  order: 6;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.gift-hero__chips:empty {
  display: none;
}

.gift-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 0 12px 0 10px;
  border: 1px solid rgba(214, 176, 184, 0.9);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: #9a5366;
  font: inherit;
  font-size: 13px;
  font-weight: 500;
  line-height: 1;
  cursor: pointer;
}

.gift-chip svg {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
}

.gift-chip:hover {
  background: #fff;
  border-color: #e7b3c0;
}

/* Mobile: the still life is the card. Copy sits on top of it. */
@media (max-width: 53.125rem) {
  .gift-hero {
    align-items: stretch;
    justify-content: flex-start;
    gap: 8px;
    width: 100%;
    max-width: none;
    min-height: clamp(27rem, 118vw, 29.5rem);
    padding: 16px 14px 14px;
    background: #f4e6e1;
  }

  .gift-hero__visual {
    position: absolute;
    inset: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
    max-width: none;
    margin: 0;
    aspect-ratio: auto;
    pointer-events: none;
    -webkit-mask-image: none;
    mask-image: none;
  }

  .gift-hero .gift-hero__photo {
    object-fit: cover;
    object-position: 74% 40%;
  }

  .gift-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background:
      linear-gradient(105deg, rgba(255, 247, 244, 0.9) 0%, rgba(255, 247, 244, 0.62) 26%, rgba(255, 247, 244, 0.16) 46%, transparent 60%),
      linear-gradient(180deg, rgba(255, 247, 244, 0.22) 0%, transparent 34%);
  }

  .gift-hero__eyebrow,
  .gift-hero__title,
  .gift-hero__lead,
  .gift-hero__btn,
  .gift-hero__chips {
    position: relative;
    z-index: 2;
  }

  .gift-hero__eyebrow {
    justify-content: flex-start;
  }

  .gift-hero__title {
    max-width: 6.25em;
    font-size: clamp(27px, 7.1vw, 33px);
    line-height: 1.02;
    text-align: left;
  }

  .gift-hero__lead {
    max-width: 15ch;
    margin: 6px 0 0;
    font-size: 12.5px;
    line-height: 1.35;
    text-align: left;
    color: #4e4644;
  }

  .gift-hero__btn {
    align-self: stretch;
    width: auto;
    max-width: none;
    min-height: 46px;
    margin: auto 0 0;
    white-space: nowrap;
  }

  .gift-hero__chips {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    width: 100%;
    max-width: none;
    gap: 8px;
  }

  .gift-hero__chips .gift-chip {
    justify-content: center;
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    min-height: 36px;
    padding: 0 8px;
    gap: 5px;
    font-size: 12px;
    white-space: nowrap;
    background: rgba(255, 252, 251, 0.82);
  }
}

@media (max-width: 23.75rem) {
  .gift-hero {
    width: calc(100% + 2rem);
    margin-left: -1rem;
    margin-right: -1rem;
    padding: 14px 10px 12px;
    gap: 6px;
  }

  .gift-hero__title {
    font-size: 28px;
  }

  .gift-hero__btn {
    font-size: 14px;
    padding: 0 12px;
    gap: 6px;
  }

  .gift-hero__chips {
    gap: 6px;
  }

  .gift-hero__chips .gift-chip {
    min-height: 34px;
    padding: 0 6px;
    gap: 4px;
    font-size: 11px;
  }

  .gift-hero__chips .gift-chip svg {
    width: 14px;
    height: 14px;
  }
}

@media (min-width: 40rem) and (max-width: 53.125rem) {
  .gift-hero {
    width: min(100%, 46.25rem);
    max-width: 46.25rem;
    min-height: 36rem;
    margin-left: auto;
    margin-right: auto;
  }

  .gift-hero .gift-hero__photo {
    object-position: 62% 30%;
  }

  .gift-hero__title {
    max-width: 8.4em;
    font-size: 40px;
  }

  .gift-hero::before {
    background:
      linear-gradient(100deg, rgba(255, 247, 244, 0.46) 0%, rgba(255, 247, 244, 0.18) 18%, transparent 34%);
  }

  .gift-hero__lead {
    max-width: 26ch;
    margin-top: 8px;
    font-size: 14px;
  }
}

@media (min-width: 53.1875rem) {
  .gift-hero {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: stretch;
    width: 100%;
    max-width: none;
    aspect-ratio: auto;
    height: 420px;
    min-height: 0;
    padding: 28px 50% 24px 36px;
    background:
      radial-gradient(70% 80% at 8% 100%, rgba(255, 244, 236, 0.95), transparent 50%),
      linear-gradient(100deg, #fffaf8 0%, #fdf4f0 55%, #f8e6e2 100%);
  }

  .gift-hero__copy {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    min-width: 0;
    max-width: 560px;
  }

  .gift-hero__eyebrow,
  .gift-hero__title,
  .gift-hero__lead,
  .gift-hero__btn,
  .gift-hero__chips {
    order: 0;
  }

  .gift-hero__eyebrow {
    justify-content: flex-start;
    margin-bottom: 12px;
  }

  .gift-hero__title {
    font-size: clamp(38px, 3.6vw, 60px);
    text-align: left;
  }

  .gift-hero__lead {
    max-width: min(22rem, 100%);
    margin: 12px 0 0;
    text-align: left;
  }

  .gift-hero__btn {
    align-self: flex-start;
    margin: 16px 0 0;
  }

  .gift-hero__chips {
    justify-content: flex-start;
    gap: 8px;
    max-width: none;
    margin-top: 16px;
  }

  .gift-hero__visual {
    position: absolute;
    z-index: 0;
    top: 0;
    right: 0;
    bottom: auto;
    left: auto;
    width: auto;
    height: 100%;
    margin: 0;
    aspect-ratio: 1492 / 1246;
    max-width: 72%;
    pointer-events: none;
  }

  .gift-hero .gift-hero__photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
  }
}

@media (min-width: 75rem) {
  .gift-hero {
    height: 475px;
    min-height: 0;
    padding: 32px 50% 28px 68px;
  }

  .gift-hero__chips {
    max-width: 100%;
  }

  .gift-hero__title {
    font-size: 52px;
  }

  .gift-hero__chips {
    display: grid;
    grid-template-columns: repeat(3, max-content);
    justify-content: start;
    gap: 8px;
  }
}

@media (min-width: 53.1875rem) and (max-width: 109.9375rem) {
  .gift-hero {
    background: #fff6f2 url("../glavnaya/gifts/merary-gifts-desktop-standard-q95.webp") center center / cover no-repeat;
  }

  .gift-hero__visual {
    display: none;
  }
}

@media (min-width: 110rem) {
  .gift-hero {
    background: #fff6f2 url("../glavnaya/gifts/merary-desktop-wide-original-lossless.webp") center center / cover no-repeat;
  }

  .gift-hero__visual {
    display: none;
  }
}

@media (min-width: 90rem) {
  .gift-hero {
    height: 500px;
  }
}

@media (min-width: 96.75rem) {
  .gift-hero {
    height: calc(525px / var(--site-scale, 1));
  }
}

.gift-dock {
  display: none;
}

@media (max-width: 53.125rem) {
  .merary-gift-upgrade:not(.is-gift-ready) {
    display: none;
  }

  .merary-gift-upgrade__glow,
  .merary-gift-upgrade__header,
  .merary-gift-upgrade__grid,
  .merary-gift-upgrade__footer-note,
  .gift-showcase {
    display: none;
  }

  .merary-gift-upgrade__shell {
    padding: 0;
    border-radius: 18px;
    background: transparent;
    box-shadow: none;
    overflow: visible;
    max-width: 100%;
  }

}

html.gift-dock-open,
html.gift-dock-open body {
  overflow: hidden;
}

.gift-dock {
  position: fixed;
  inset: 0;
  z-index: 10070;
  align-items: flex-end;
  justify-content: center;
  background: rgba(43, 23, 26, 0.42);
  font-family: var(--font-sans, 'Montserrat', Arial, Helvetica, sans-serif);
}

.gift-dock button,
.gift-dock input,
.gift-dock textarea {
  font-family: inherit;
}

.gift-dock.is-open {
  display: flex;
}

.gift-dock__sheet {
  display: flex;
  flex-direction: column;
  width: min(100%, 480px);
  height: auto;
  max-height: min(85dvh, calc(100dvh - env(safe-area-inset-top) - 8px));
  overflow: hidden;
  border-radius: 22px 22px 0 0;
  background: #fffdfc;
  color: #2f2927;
  box-shadow: 0 -8px 28px rgba(47, 41, 39, 0.08);
}

.gift-dock__head {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 10px;
}

.gift-dock__title {
  margin: 0;
  font-family: var(--font-serif, 'Playfair Display', Georgia, serif);
  font-size: clamp(20px, 5.6vw, 24px);
  line-height: 1.2;
  font-weight: 400;
}

.gift-dock__back {
  display: none;
  flex: 0 0 auto;
  align-items: center;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(226, 190, 196, 0.9);
  border-radius: 999px;
  background: #fff;
  color: #2f2927;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.gift-dock.is-detail .gift-dock__back {
  display: inline-flex;
}

.gift-dock.is-detail .gift-dock__title {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.gift-dock__close {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  background: #fff1f4;
  color: #2f2927;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.gift-dock__tabs {
  display: flex;
  flex: 0 0 auto;
  gap: 8px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  padding: 2px 16px 14px;
  scroll-padding-inline: 16px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.gift-dock__tabs::-webkit-scrollbar {
  display: none;
}

.gift-dock__tabs.can-scroll:not(.is-end) {
  -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 22px), transparent);
  mask-image: linear-gradient(90deg, #000 calc(100% - 22px), transparent);
}

.gift-dock__tabs.can-scroll.is-scrolled.is-end {
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 22px);
  mask-image: linear-gradient(90deg, transparent, #000 22px);
}

.gift-dock__tabs.can-scroll.is-scrolled:not(.is-end) {
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 22px, #000 calc(100% - 22px), transparent);
  mask-image: linear-gradient(90deg, transparent, #000 22px, #000 calc(100% - 22px), transparent);
}

.gift-dock__tabs[hidden] {
  display: none;
}

.gift-dock__tab {
  flex: 0 0 auto;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(226, 190, 196, 0.9);
  border-radius: 999px;
  background: #fff;
  color: #2f2927;
  font: inherit;
  font-size: 13px;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
}

.gift-dock__tab.is-active {
  border-color: #e86f91;
  background: #fff1f4;
  color: #9a3d58;
  font-weight: 600;
}

.gift-dock__browse {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-height: 0;
}

.gift-dock.is-detail .gift-dock__browse {
  display: none;
}

.gift-dock__list {
  flex: 1 1 auto;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding: 2px 14px 8px;
}

.gift-dock__item {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  margin: 0 0 10px;
  padding: 10px;
  border: 1px solid rgba(226, 190, 196, 0.72);
  border-radius: 16px;
  background: #fff7f8;
}

.gift-dock__item:last-child {
  margin-bottom: 2px;
}

.gift-dock__shot {
  display: block;
  width: 104px;
  height: 104px;
  padding: 0;
  border: 0;
  border-radius: 12px;
  overflow: hidden;
  background: #f7f1f2;
  cursor: pointer;
}

.gift-dock__item img,
.gift-dock__shot img {
  display: block;
  width: 104px;
  height: 104px;
  object-fit: cover;
  border-radius: 12px;
  background: #f7f1f2;
}

.gift-dock__shot img {
  width: 100%;
  height: 100%;
  border-radius: 0;
}

.gift-dock__name {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  color: #2f2927;
  font: inherit;
  font-size: 15px;
  line-height: 1.35;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
}

.gift-dock__price {
  margin: 4px 0 10px;
  color: #2f2927;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.gift-dock__add {
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid rgba(226, 190, 196, 0.95);
  border-radius: 999px;
  background: #fff;
  color: #2f2927;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.gift-dock__add.is-added {
  border-color: #e86f91;
  background: #fff1f4;
  cursor: default;
}

.gift-dock__empty {
  margin: 24px 0;
  color: #827a78;
  font-size: 14px;
  text-align: center;
}

.gift-dock__foot {
  flex: 0 0 auto;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  border-top: 1px solid rgba(238, 212, 216, 0.9);
  background: #fffdfc;
}

.gift-dock__continue {
  width: 100%;
  min-height: 48px;
  border: 0;
  border-radius: 999px;
  background: #2f2927;
  color: #fff;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.gift-dock__detail {
  display: none;
  flex: 1 1 auto;
  flex-direction: column;
  min-height: 0;
}

.gift-dock.is-detail .gift-dock__detail {
  display: flex;
  animation: giftDockIn 0.18s ease;
}

.gift-dock__detail-body {
  box-sizing: border-box;
  flex: 1 1 auto;
  min-height: 0;
  min-width: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-gutter: stable;
  padding: 2px 16px 16px;
}

.gift-dock__hero,
.gift-dock__slides img {
  display: block;
  width: 100%;
  height: min(36dvh, 300px);
  object-fit: cover;
  border-radius: 18px;
  background: #f7f1f2;
}

.gift-dock__gallery {
  position: relative;
}

.gift-dock__slides {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  border-radius: 18px;
  scrollbar-width: none;
}

.gift-dock__slides::-webkit-scrollbar {
  display: none;
}

.gift-dock__slides img {
  flex: 0 0 100%;
  scroll-snap-align: center;
  border-radius: 0;
}

.gift-dock__nav {
  position: absolute;
  top: calc(min(36dvh, 300px) / 2);
  left: 8px;
  width: 44px;
  height: 44px;
  margin-top: -22px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 253, 252, 0.92);
  color: #2f2927;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.gift-dock__nav--next {
  left: auto;
  right: 8px;
}

.gift-dock__count {
  margin: 8px 0 0;
  color: #827a78;
  font-size: 13px;
  text-align: center;
}

.gift-dock__detail-name {
  margin: 14px 0 0;
  color: #2f2927;
  font-family: var(--font-serif, 'Playfair Display', Georgia, serif);
  font-size: clamp(22px, 6vw, 28px);
  font-weight: 400;
  line-height: 1.25;
  overflow-wrap: break-word;
}

.gift-dock__detail-price {
  margin: 8px 0 0;
  color: #2f2927;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.gift-dock__detail-text {
  margin: 14px 0 0;
  color: #4a4341;
  font-size: 14px;
  line-height: 1.45;
  white-space: pre-line;
  overflow-wrap: break-word;
}

.gift-dock__specs {
  margin: 4px 0 0;
}

.gift-dock__specs div {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 10px 0;
  border-top: 1px solid rgba(238, 212, 216, 0.9);
}

.gift-dock__specs dt,
.gift-dock__specs dd {
  margin: 0;
  overflow-wrap: break-word;
}

.gift-dock__specs dt {
  color: #827a78;
  font-size: 13px;
  line-height: 1.35;
}

.gift-dock__specs dd {
  color: #2f2927;
  font-size: 15px;
  line-height: 1.45;
  white-space: pre-line;
}

.gift-dock__choice {
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  margin: 16px 0 0;
  padding: 0;
  border: 0;
}

.gift-dock__choice legend {
  margin-bottom: 8px;
  color: #2f2927;
  font-size: 14px;
  font-weight: 600;
}

.gift-dock__options {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  min-width: 0;
}

.gift-dock__option {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 44px;
  margin: 0;
  padding: 8px 10px;
  border: 1px solid rgba(226, 190, 196, 0.95);
  border-radius: 12px;
  background: #fff;
}

.gift-dock__option-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.gift-dock__option-name {
  color: #2f2927;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.3;
  overflow-wrap: break-word;
}

.gift-dock__option:has(input:checked) {
  background: #fff1f4;
  border-color: #e86f91;
}

.gift-dock__option:has(input:focus-visible) {
  outline: 2px solid #e86f91;
  outline-offset: 2px;
}

.gift-dock__option input {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  margin: 0;
  border: 1.5px solid #e2bec4;
  border-radius: 50%;
  background: #fff;
  box-shadow: inset 0 0 0 4px #fff;
}

.gift-dock__option input:checked {
  border-color: #e86f91;
  background: #e86f91;
}

.gift-dock__option input:focus-visible {
  outline: none;
}

.gift-dock__surcharge {
  color: #9a3d58;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
}

.gift-dock__inscription {
  box-sizing: border-box;
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 88px;
  max-height: 140px;
  margin: 8px 0 0;
  padding: 12px;
  border: 1px solid rgba(226, 190, 196, 0.9);
  border-radius: 12px;
  background: #fff;
  color: #2f2927;
  font: inherit;
  font-size: 15px;
  line-height: 1.45;
  white-space: pre-wrap;
  overflow-wrap: break-word;
  resize: vertical;
}

.gift-dock__inscription[hidden] {
  display: none !important;
}

@media (min-width: 360px) {
  .gift-dock__options {
    grid-template-columns: 1fr 1fr;
  }
}

.gift-dock__info {
  margin-top: 14px;
  border-top: 1px solid rgba(238, 212, 216, 0.9);
}

.gift-dock__info summary {
  display: flex;
  align-items: center;
  min-height: 44px;
  color: #2f2927;
  font-weight: 600;
  cursor: pointer;
}

.gift-dock__hint {
  min-height: 18px;
  margin: 0 0 8px;
  color: #9a3d58;
  font-size: 13px;
  text-align: center;
}

.gift-dock__buy {
  width: 100%;
  min-height: 48px;
  border: 0;
  border-radius: 999px;
  background: #e86f91;
  color: #fff;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.gift-dock__buy.is-added {
  border: 1px solid #e86f91;
  background: #fff1f4;
  color: #9a3d58;
  cursor: default;
}

.gift-dock__buy:disabled {
  cursor: default;
  opacity: 0.46;
}

@keyframes giftDockIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .gift-dock.is-detail .gift-dock__detail {
    animation: none;
  }
}

@media (min-width: 53.1875rem) {
  .gift-dock.is-open {
    align-items: center;
    padding: 28px 24px;
  }

  .gift-dock__sheet {
    width: min(760px, 100%);
    max-height: min(78dvh, 820px);
    border-radius: 22px;
    box-shadow: 0 24px 64px rgba(47, 41, 39, 0.18);
  }
}
